Method and apparatus for correcting multi-exposure motion image

ABSTRACT

A method and an apparatus for correcting a multi-exposure motion image are disclosed, where the method includes determining a luminance mapping function, where the luminance mapping function is a luminance mapping relationship between a reference frame and multiple extended frames; mapping a luminance of an extended frame by using the luminance mapping relationship to obtain a virtual frame; calculating a global motion vector between the virtual frame and the reference frame; correcting a pixel of the extended frame according to the global motion vector to obtain a first extended frame after correction; detecting a pixel of the first extended frame according to the reference frame to obtain a local error pixel of the first extended frame; and correcting a luminance of the local error pixel of the first extended frame to obtain a second extended frame after correction.

CROSS-REFERENCE TO RELATED APPLICATIONS

This application is a continuation of International Application No.PCT/CN2013/070244, filed on Jan. 9, 2013, which claims priority toChinese Patent Application No. 201210259363.8, filed on Jul. 20, 2012,both of which are hereby incorporated by reference in their entireties.

TECHNICAL FIELD

The present invention relates to image processing technologies, and inparticular, to a method and an apparatus for correcting a multi-exposuremotion image.

BACKGROUND

With the development of multi-frame exposure composition high dynamicrange (HDR) imaging technologies, in a current consumer market, an HDRphotography function is integrated into a smart phone, such as anIPHONE. That is, in a scenario in which a camera stays stable or still,a photography effect is improved to different degrees, and a capabilityof presenting details in a bright or dark place is improvedcorrespondingly.

However, in a scenario in which a camera shakes or a moving objectexists, a poor condition such as a ghost or a blur occurs in an HDRimage composited by multi-exposure frames. Frames photographed atdifferent exposure levels significantly differ in luminance.

In the prior art 1, in order to correct an image composited bymulti-exposure frames in a motion process, a motion correction method isprovided. In this method, mapping is first performed according to amapping relationship between an exposure frame and a camera responsecurve, and a luminance of a dark frame is improved; then, a frame-levelmotion vector is calculated by using a bi-directional prediction method,and correction is performed for the motion vector; finally, local motionis corrected by using a gradient-based optical flow method. However, themethod is not only extremely complex but also has an unsatisfactorycorrection effect because the camera response curve needs to be obtainedby using an image sensor and another processing module.

In the prior art 2, a motion correction method is further provided. Inthis method, a luminance of a first frame is corrected to a luminancerange of a second frame by using a luminance mapping function, and thena motion condition between the two frames is detected; and for a motionarea, a luminance value of the area which is mapped from the first frameis used to directly replace a pixel value corresponding to the secondframe.

However, when a camera moves during photographing, all areas detected byusing this method are motion areas, a second frame image corrected bymeans of replacement has basically lost detail information under theexposure condition, and an effect of a finally composited HDR image isalso unsatisfactory. Motion areas determination is relatively difficult,especially for an exposure frame that undergoes luminance mapping, andit is difficult to ensure a result of the motion areas determination dueto a different noise level/an over-exposure or under-exposure area.Therefore, a phenomenon of obvious discontinuity in the second frameimage after correction likely occurs on an edge of a motion area, whichdirectly affects a final HDR composition effect.

Therefore, in the process of research and practice in the prior art, theinventor of the present invention finds that in an existingimplementation manner, no matter in the prior art 1 or in the prior art2, a multi-exposure frame motion image cannot be effectively correctedin a scenario in which a camera shakes or a moving object exists.

SUMMARY

Embodiments of the present invent provide a method and an apparatus forcorrecting a multi-exposure motion image, so as to solve a technicalproblem in the prior art that a multi-exposure frame motion image cannotbe effectively corrected.

An embodiment of the present invention provides a method for correctinga multi-exposure motion image, including determining a luminance mappingfunction, where the luminance mapping function is a luminance mappingrelationship between a reference frame and multiple extended frames;mapping a luminance of an extended frame by using the luminance mappingrelationship to obtain a virtual frame; calculating a global motionvector between the virtual frame and the reference frame; correcting apixel of the extended frame according to the global motion vector toobtain a first extended frame after correction; detecting a pixel of thefirst extended frame according to the reference frame to obtain a localerror pixel of the first extended frame; and correcting a luminance ofthe local error pixel of the first extended frame to obtain a secondextended frame after correction.

Correspondingly, an embodiment of the present invention further providesan apparatus for correcting a multi-exposure motion image, including adetermining unit configured to determine a luminance mapping function,where the luminance mapping function is a luminance mapping relationshipbetween a reference frame and multiple extended frames; a mapping unitconfigured to map a luminance of an extended frame by using theluminance mapping relationship to obtain a virtual frame; a firstcalculating unit configured to calculate a global motion vector betweenthe virtual frame and the reference frame; a first correcting unitconfigured to correct a pixel of the extended frame according to theglobal motion vector to obtain a first extended frame after correction;a detecting unit configured to detect a pixel of the first extendedframe according to the reference frame to obtain a local error pixel ofthe first extended frame; and a second correcting unit configured tocorrect a luminance of the local error pixel of the first extended frameto obtain a second extended frame after correction.

It may be learnt from the forgoing technical solutions that in theembodiments of the present invention, an extended frame is corrected byusing a luminance mapping function, correcting global motion, andcorrecting a local error pixel, so as to solve a technical problem inthe prior art that a multi-exposure frame motion image cannot beeffectively corrected, that is, in the embodiments, motion betweenmulti-frame exposure images can be effectively corrected, where themotion may include global motion caused by motion of a camera and motionof an object in a scene.

BRIEF DESCRIPTION OF THE DRAWINGS

To describe the technical solutions in the embodiments of the presentinvention more clearly, the following briefly introduces theaccompanying drawings required for describing the embodiments. Theaccompanying drawings in the following description show merely someembodiments of the present invention, and a person of ordinary skill inthe art may still derive other drawings from these accompanying drawingswithout creative efforts.

FIG. 1 is a flowchart of a method for correcting a multi-exposure motionimage according to an embodiment of the present invention;

FIG. 2 is a schematic line graph of a luminance mapping functionaccording to an embodiment of the present invention;

FIG. 3 is a flowchart of a method for correcting a local error pixelaccording to an embodiment of the present invention;

FIG. 4 is a schematic structural diagram of an apparatus for correctinga multi-exposure motion image according to an embodiment of the presentinvention;

FIG. 5 is a second schematic structural diagram of an apparatus forcorrecting a multi-exposure motion image according to an embodiment ofthe present invention; and

FIG. 6 is a third schematic structural diagram of an apparatus forcorrecting a multi-exposure motion image according to an embodiment ofthe present invention.

DETAILED DESCRIPTION

The following clearly describes the technical solutions in theembodiments of the present invention with reference to the accompanyingdrawings in the embodiments of the present invention. The describedembodiments are merely a part rather than all of the embodiments of thepresent invention. All other embodiments obtained by a person ofordinary skill in the art based on the embodiments of the presentinvention without creative efforts shall fall within the protectionscope of the present invention.

Referring to FIG. 1, FIG. 1 is a flowchart of a method for correcting amulti-exposure motion image according to an embodiment of the presentinvention, where the method includes the following steps.

Step 101: Determine a luminance mapping function, where the luminancemapping function is a luminance mapping relationship between a referenceframe and multiple extended frames.

In this step, the luminance mapping function F(x) is the luminancemapping relationship between a reference frame and multiple extendedframes, where the luminance mapping function may be obtained bycalculating a statistical histogram of a reference frame and multipleextended frames, as shown in FIG. 2. FIG. 2 is a schematic line graph ofa luminance mapping function according to an embodiment of the presentinvention. In FIG. 2, a horizontal coordinate represents a luminance ofan extended frame image, that is, a luminance of an extended frame,where a large number of over-exposed pixels exist in the extended frameimage; and a vertical coordinate represents a luminance of a referenceframe image, that is, a luminance of a reference frame.

In addition, in a general case, an exposure value of a camera isdetermined by an exposure line and a gain; and a multi-frame exposureimage refers to an image obtained by a camera by performingphotographing at differently configured exposure values. In HDR imaging,images obtained by taking photographs of two or more frames at differentexposure values are normally required. In this embodiment, it is definedthat an image frame obtained by taking a photograph at a best exposurevalue in a current scenario is referred to as a reference frame. Framesexcept the reference frame are referred to as extended frames. For amulti-frame exposure image, a best exposure frame is generally anexposure frame obtained by taking a photograph at an intermediateexposure value.

Step 102: Map a luminance of an extended frame by using the luminancemapping relationship to obtain a virtual frame.

In this step, the luminance mapping function may be used to map theextended frame to obtain a luminance histogram, thereby obtaining avirtual frame similar to the reference frame. That is, except for anover-exposure area, an under-exposure area, and a motion area, aluminance of the virtual frame is extremely close to the luminance ofthe reference frame.

Step 103: Calculate a global motion vector between the virtual frame andthe reference frame.

In this embodiment, the global motion vector between the virtual frameand the reference frame may be calculated in a manner of choosing areference block. The global motion vector in this embodiment may includea translational motion vector and a rotational motion vector, where acalculation method of the global motion vector is the same as that of anordinary (e.g., a non-HDR) image. Calculating global translationalmotion is used as an example in this embodiment, which includes thefollowing.

First, a reference frame image is divided into fixed-size imagesub-blocks (for example, 64×64). A mean luminance and a standarddeviation of each sub-block are collected by means of statistics, and animage sub-block which has an excessively dark or bright mean luminanceor has an excessively small standard deviation (that is, a flat area) isremoved. From remaining image sub-blocks, a specified quantity (forexample 9) of image sub-blocks are chosen as reference blocks. Locationsof reference blocks (i0, j0), . . . , and (i9, j9) are recorded, andthese reference blocks are evenly distributed in locations of an image.

Then, according to the following block matching formula, a translationalvector is calculated by using the reference blocks, where the formula isas follows:min_(mxε[−tx,tx]myε[−ty,ty]){Σ_(k=0) ⁹∥ref(ik,jk),ext(ik+mx,jk+my)∥}where tx, ty indicates a maximum range of image motion; (mx, my) is apossible motion vector; ref(ik, jk) refers to the k^(th) reference blockin a reference frame; ext(ik+mx, jk+my) is the k^(th) reference blockwhich is offset by mx, my in the virtual frame; and ∥ref(ik, jk),ext(ik+mx, jk+my)∥ is the Euclidean distance between two image blocks,that is, the sum of absolute differences of corresponding points of thetwo image blocks.

Finally, mx, my corresponding to the minimum differences is a globalmotion vector.

A specific process of calculating global translational motion is awell-known technology to a person skilled in the art, and details arenot repeatedly described herein.

In addition, in this embodiment, in a case in which a relatively highreal-time requirement is imposed, only global translational motion maybe calculated, or both global translational motion and rotational motionmay be calculated. For the former case, an error caused by therotational motion may be left to be corrected together with a subsequentlocal error pixel. Certainly, the global translational motion androtational motion may also be calculated, where a global translationalmotion vector is obtained by calculating the global translationalmotion, and a global rotational motion vector is obtained by calculatingthe rotational motion.

Step 104: Correct a pixel of the extended frame according to the globalmotion vector to obtain a first extended frame after correction.

In this embodiment, if only reference frame correction for translationalmotion is considered during correction, most of pixel correction may becompleted in a simple pointer offset manner. If translational motionamount of a virtual frame relative to the reference frame is (a, b),that is, a pixel of coordinate (0, 0) in the reference frame correspondsto (a, b) in the virtual frame, where width and height of the image is(w, h), and a memory pointer of an original extended frame luminance isp, and a pointer obtained after correction is p+b*w+a. An offset virtualframe causes a “vacant” pixel around the image. For correction on the“vacant” pixel, a method of supplementing a closest pixel may be used;alternatively, a pixel in a corresponding location in the referenceframe may be obtained by means of mapping according to the luminancemapping function. This is a known technology to a person skilled in theart, and details are not repeatedly described herein.

Certainly, if reference frame correction for both translational motionand rotational motion is considered, the pixel of the extended frame maybe corrected in an interpolation manner, so as to obtain a firstextended frame after correction, that is, a virtual frame aftercorrection is obtained by using an interpolation method. For a vacantpixel, a supplementing method in which “only translational motion isconsidered” may be adopted. For details, refer to the foregoingdescription, and detail are not repeatedly described herein.

Step 105: Detect a pixel of the first extended frame according to thereference frame to obtain a local error pixel of the first extendedframe.

After correction in the foregoing step is performed, pixels which arenot corresponding to each other between the extended frame after globalmotion correction and the reference frame are greatly reduced, but asmall quantity of asymmetric pixels still exist, which is mainly causedin the following several situations: 1. inaccurate calculation of globalmotion; 2. a rotational case not considered during global motion; 3. amotion parallax formed due to a different scene depth; 4. local motionand a motion blur of an object in a scene; and 5. an expanding outlineof an over-exposure area in a long-time exposed image. In thisembodiment, these pixels which are not corresponding to each other arecollectively referred to as local error pixels whose commoncharacteristic is as follows. A difference between a mapping value,which is obtained by means of mapping by performing an inverse functionof a luminance mapping function on a pixel of a reference frame, and apixel value corresponding to the extended frame goes beyond a properrange.

Correct a luminance of the local error pixel of the first extended frameto obtain a second extended frame after correction.

In this step, a method for correcting a local error pixel is provided,and a flowchart of the method for correcting a local error pixel isshown in FIG. 3, to which the method is not limited. The method includesthe following steps.

Step 301: Calculate a luminance value range of the first extended frame.

One calculation method is to use an inverse function of the luminancemapping function to obtain a luminance value x of a pixel location ofthe first extended frame; map the luminance value x to obtain anexpected value fx; and determine that the luminance value range of thefirst extended frame is [fx−ix, fx+ax] according to the luminance valuex, the expected value fx, and an exposure relationship between theextended frame and the reference frame, where the ix and ax are fixedlimit constants. However, this embodiment is not limited to thiscalculation manner, and another similar calculation manner may be used,which is not limited in this embodiment.

Step 302: Determine whether a luminance value of the first extendedframe is within the range; if the luminance value of the first extendedframe is within the range, perform step 303; and if the luminance valueof the first extended frame is not within the range, perform step 304.

Step 303: Directly output or store the first extended frame without aneed to modify a luminance of the first extended frame.

Step 304: Modify the luminance value of the first extended frame toobtain a second extended frame after modification, and output or storethe second extended frame.

That is, the inverse function of the luminance mapping function is usedto obtain a luminance value x (for example, 160) of the pixel locationof the first extended frame, the luminance value x is mapped to obtainan expected value fx (for example, 90), and then a proper range [fx−ix,fx+ax], for example [82, 106], is estimated according to the exposurerelationship between the extended frame and the reference frame, whereix and ax may also be fixed limit constants, for example, 16, which is aminor change threshold that can be perceived by human eyes. If aluminance value (for example, 60) of a corresponding pixel location ofthe extended frame does not belong to a pixel within the proper range,the corresponding pixel is a local error pixel. A specific method forcorrecting the local error pixel may be to replace the luminance value(for example, 60) with a simple expected value fx (for example, 90), orreplace the luminance value (for example, 60) with a minimum value (forexample, 82) of absolute difference values between all values within theproper range and x.

Optionally, in this embodiment, to make an extended frame (for example,the first extended frame) before and after correction relatively smooth,the following formula may also be used to modify a luminance value ofthe extended frame, and the formula is:

x^(′) = a * Thr + (1 − a) * x a = min (1, Thr − x/β)${Thr} = \left\{ {\begin{matrix}{{{fx} - {{ix}\mspace{14mu}{when}\mspace{14mu} x}} < {{fx} - {ix}}} \\{{{fx} + {{ax}\mspace{14mu}{when}\mspace{14mu} x}} > {{fx} + {ax}}}\end{matrix},} \right.$where the a is a weighting coefficient obtained by means of calculation,the x is a luminance value, the fx is an expected value, the Thr is aclosest expected value, and β is a smooth control coefficient, which maybe assigned 8, 16, 32, or the like for ease of calculation. This is awell-known technology to a person skilled in the art, and details arenot repeatedly described herein.

In another embodiment of the present invention, in a case in which arelatively high requirement on a correction effect is imposed, bothglobal translational motion and rotational motion may be calculated, andthen a virtual frame after correction is obtained by using aninterpolation method. For a vacant pixel after correction, asupplementing method in which “only translational motion is considered”may be adopted for correction. The embodiment of the present inventionprovides a fast electronic image stabilization algorithm forcompensating translational motion and rotational motion, where thealgorithm is to first estimate and compensate translational motionbetween video image sequences by using a gray scale projectionalgorithm, choose several small blocks with an obvious characteristicfrom an edge area close to an image edge by using Laplace transform,perform matching by using a block matching algorithm, and calculate andcompensate an amount of rotational motion thereof, so as to obtainstable video image sequences. By means of theoretical analysis andexperimental verification, it is indicated that the image stabilizationalgorithm features a high speed and high accuracy. The specificimplementing process thereof is a technology well-known to a personskilled in the art, and details are not repeatedly described herein.

In this embodiment of the present invention, an extended frame iscorrected by using a luminance mapping function, correcting globalmotion, and correcting a local error pixel, so as to solve a technicalproblem in the prior art that a multi-exposure frame motion image cannotbe effectively corrected, that is, motion between multi-frame exposureimages can be effectively corrected in this embodiment, where the motionmay include global motion caused by motion of a camera and motion of anobject in a scene. Further, in this embodiment, an image frame aftercorrection can be smoothly transitioned at a boundary of a motion areawithout a need to calibrate a camera in advance.

Based on the implementing process of the foregoing method, an embodimentof the present invention further provides an apparatus for correcting amulti-exposure motion image, and a schematic structural diagram of theapparatus is shown in FIG. 4. The correcting apparatus includes adetermining unit 41, a mapping unit 42, a first calculating unit 43, afirst correcting unit 44, a detecting unit 45, and a second correctingunit 46, where the determining unit 41 is configured to determine aluminance mapping function, where the luminance mapping function is aluminance mapping relationship between a reference frame and multipleextended frames; the mapping unit 42 is configured to map a luminance ofan extended frame by using the luminance mapping relationship to obtaina virtual frame; the first calculating unit 43 is configured tocalculate a global motion vector between the virtual frame and thereference frame; the first correcting unit 44 is configured to correct apixel of the extended frame according to the global motion vector toobtain a first extended frame after correction; the detecting unit 45 isconfigured to detect a pixel of the first extended frame according tothe reference frame to obtain a local error pixel of the first extendedframe; and the second correcting unit 46 is configured to correct aluminance of the local error pixel of the first extended frame to obtaina second extended frame after correction.

The second correcting unit 46 includes a second calculating unit 461 anda modifying unit 462, where the second calculating unit 461 isconfigured to calculate a luminance value range of the first extendedframe; and the modifying unit 462 is configured to, when a luminancevalue of the first extended frame is not within the range, modify theluminance value of the first extended frame to obtain a second extendedframe after modification. A schematic structural diagram of theapparatus is shown in FIG. 5. FIG. 5 is a second schematic structuraldiagram of an apparatus for correcting a multi-exposure motion imageaccording to an embodiment of the present invention.

Further referring to FIG. 6, FIG. 6 is a third schematic structuraldiagram of an apparatus for correcting a multi-exposure motion imageaccording to an embodiment of the present invention. This embodiment isbased on the embodiment described in FIG. 5.

The second calculating unit 461 includes a luminance value determiningunit 4611, an expected value determining unit 4612, and a rangedetermining unit 4613. The luminance determining unit 4611 is configuredto obtain a luminance value x of a pixel location of the first extendedframe by using an inverse function of the luminance mapping function;the expected value determining unit 4612 is configured to map theluminance value to obtain an expected value fx; and the rangedetermining unit 4613 is configured to determine that the luminancevalue range of the first extended frame is [fx−ix, fx+ax] according tothe luminance value x, the expected value fx, and an exposurerelationship between the extended frame and the reference frame, whereix and ax are fixed limit constants.

The modifying unit 462 includes a first modifying unit 4621, a secondmodifying unit 4622, and/or a third modifying unit 4623, where the firstmodifying unit 4621 is configured to modify the luminance value of thefirst extended frame as the expected value fx; the second modifying unit4622 is configured to modify the luminance value of the first extendedframe as a minimum value of absolute difference values between allvalues within the range [fx−ix, fx+ax] and the luminance value x; andthe third modifying unit 4623 is configured to modify the luminancevalue of the first extended frame according to a formula, where theformula is:

x^(′) = a * Thr + (1 − a) * x a = min (1, Thr − x/β)${Thr} = \left\{ {\begin{matrix}{{{fx} - {{ix}\mspace{14mu}{when}\mspace{14mu} x}} < {{fx} - {ix}}} \\{{{fx} + {{ax}\mspace{14mu}{when}\mspace{14mu} x}} > {{fx} + {ax}}}\end{matrix},} \right.$where the a is a weighting coefficient obtained by means of calculation,the Thr is a closest expected value, β is a smooth control coefficient,the x is a luminance value, the fx is an expected value, and the ix andax are fixed limit constants.

In this embodiment, that the modifying unit includes the first modifyingunit, the second modifying unit, and the third modifying unit is used asan example, to which this embodiment is not limited.

For details of implementing processes of functions and roles of eachunit in the apparatus, refer to the corresponding implementing processesin the foregoing method, and details are not repeated herein.

It should be noted that in this specification, relational terms such asfirst and second are merely used to distinguish an entity or operationfrom another entity or operation, and do not require or imply that anyactual relationship or sequence exists between these entities oroperations. Furthermore, the terms “include”, “comprise”, or any othervariant thereof is intended to cover a non-exclusive inclusion, so thata process, a method, an article, or an apparatus that includes a list ofelements not only includes those elements but also includes otherelements which are not expressly listed, or further includes elementsinherent to such process, method, article, or apparatus. An elementpreceded by “includes a . . . ” does not, without more constraints,preclude the existence of additional identical elements in the process,method, article, or apparatus that includes the element.

Based on the foregoing descriptions of the embodiments, a person skilledin the art may clearly understand that the present invention may beimplemented by software in addition to a necessary universal hardwareplatform or by hardware only. In most circumstances, the former is apreferred implementation manner. Based on such an understanding, thetechnical solutions of the present invention essentially or the partcontributing to the prior art may be implemented in a form of a softwareproduct. The software product is stored in a readable storage medium,such as a read-only memory (ROM)/random-access memory (RAM), a magneticdisk, or an optical disc, and includes several instructions forinstructing a calculator device (which may be a personal computer, aserver, a network device, or the like) to perform the methods describedin the embodiments of the present invention.

The foregoing descriptions are merely exemplary implementation mannersof the present invention. It should be noted that a person of ordinaryskill in the art may make certain improvements or polishing withoutdeparting from the principle of the present invention and theimprovements or polishing shall fall within the protection scope of thepresent invention.

What is claimed is:
 1. A method for correcting a multi-exposure motionimage, comprising: mapping a luminance of an extended frame using aluminance mapping relationship between a reference frame and multipleextended frames to obtain a virtual frame; calculating a global motionvector between the virtual frame and the reference frame; correcting apixel of the extended frame in a pointer offset manner to obtain a firstextended frame after correction when the global motion vector comprisesa translational motion vector; correcting the pixel of the extendedframe in an interpolation manner to obtain the first extended frameafter correction when the global motion vector comprises thetranslational motion vector and a rotational motion vector; detecting apixel of the first extended frame according to the reference frame toobtain a local error pixel of the first extended frame; and correcting aluminance of the local error pixel of the first extended frame to obtaina second extended frame after correction.
 2. A method for correcting amulti-exposure motion image, comprising: mapping a luminance of anextended frame using a function, indicating relationship between areference frame and multiple extended frames to obtain a virtual frame;calculating a global motion vector between the virtual frame and thereference frame; correcting a pixel of the extended frame according tothe global motion vector to obtain a first extended frame aftercorrection; detecting a pixel of the first extended frame according tothe reference frame to obtain a local error pixel of the first extendedframe; calculating a luminance value range of the first extended frame;and modifying a luminance value of the first extended frame to obtain asecond extended frame after modification when the luminance value of thefirst extended frame is not within the luminance value range.
 3. Themethod according to claim 2, wherein correcting the luminance of thelocal error pixel of the first extended frame to obtain the secondextended frame after luminance correction further comprises skippingmodifying the luminance value of the first extended frame when theluminance value of the first extended frame is within the luminancevalue range.
 4. The method according to claim 2, wherein calculating theluminance value range of the first extended frame comprises: obtaining aluminance value x of a pixel location of the first extended frame byusing an inverse function of the luminance mapping function; mapping theluminance value x to obtain an expected value fx; and determining thatthe luminance value range of the first extended frame is [fx−ix, fx+ax]according to the luminance value x, the expected value fx, and anexposure relationship between the extended frame and the referenceframe, wherein ix and ax are fixed limit constants.
 5. The methodaccording to claim 4, wherein modifying the luminance value of the firstextended frame to obtain the second extended frame after modificationcomprises modifying the luminance value of the first extended frame asthe expected value fx.
 6. The method according to claim 4, whereinmodifying the luminance value of the first extended frame to obtain thesecond extended frame after modification comprises modifying theluminance value of the first extended frame as a minimum value ofabsolute difference values between all values within the range[fx−ix,fx+ax] and the luminance value x.
 7. The method according toclaim 4, wherein modifying the luminance value of the first extendedframe to obtain the second extended frame after modification comprisesmodifying the luminance value of the first extended frame according tothe following formula: x^(′) = a * Thr + (1 − a) * xa = min (1, Thr − x/β) ${Thr} = \left\{ {\begin{matrix}{{{fx} - {{ix}\mspace{14mu}{when}\mspace{14mu} x}} < {{fx} - {ix}}} \\{{{fx} + {{ax}\mspace{14mu}{when}\mspace{14mu} x}} > {{fx} + {ax}}}\end{matrix},} \right.$ wherein the a is a weighting coefficientobtained by means of calculation, Thr is a closest expected value, β isa smooth control coefficient, x is a luminance value, and fx is anexpected value, and ix and ax are fixed limit constants.
 8. An apparatusfor correcting a multi-exposure motion image, comprising: a memoryconfigured to store an instruction; and a processor configured toexecute the instruction stored in the memory so as to: map a luminanceof an extended frame using a function, indicating relationship between areference frame and multiple extended frames to obtain a virtual frame;calculate a global motion vector between the virtual frame and thereference frame; correct a pixel of the extended frame according to theglobal motion vector to obtain a first extended frame after correction;detect a pixel of the first extended frame according to the referenceframe to obtain a local error pixel of the first extended frame;calculate a luminance value range of the first extended frame; andmodify a luminance value of the first extended frame to obtain a secondextended frame after modification when the luminance value of the firstextended frame is not with the luminance value range.
 9. The apparatusaccording to claim 8, wherein the processor is further configured toexecute the instruction stored in the memory so as to: obtain aluminance value x of a pixel location of the first extended frame byusing an inverse function of the luminance mapping function; map theluminance value x to obtain an expected value fx; and determine that theluminance value range of the first extended frame is [fx−ix, fx+ax]according to the luminance value x, the expected value fx, and anexposure relationship between the extended frame and the referenceframe, wherein ix and ax are fixed limit constants.
 10. The apparatusaccording to claim 9, wherein the processor is further configured toexecute the instruction stored in the memory so as to modify theluminance value of the first extended frame as the expected value fx.11. The apparatus according to claim 9, wherein the processor is furtherconfigured to execute the instruction stored in the memory so as tomodify the luminance value of the first extended frame as a minimumvalue of absolute difference values between all values within the range[fx−ix, fx+ax] and the luminance value x.
 12. The apparatus according toclaim 9, wherein the processor is further configured to execute theinstruction in the memory so as to modify the luminance value of thefirst extended frame according to a formula, wherein the formula is:x^(′) = a * Thr + (1 − a) * x a = min (1, Thr − x/β)${Thr} = \left\{ {\begin{matrix}{{{fx} - {{ix}\mspace{14mu}{when}\mspace{14mu} x}} < {{fx} - {ix}}} \\{{{fx} + {{ax}\mspace{14mu}{when}\mspace{14mu} x}} > {{fx} + {ax}}}\end{matrix},} \right.$ wherein the a is a weighting coefficientobtained by means of calculation, Thr is a closest expected value, β isa smooth control coefficient, the x is a luminance value, fx is anexpected value, and ix and ax are fixed limit constants.
 13. The methodaccording to claim 1, further comprising calculating a luminance valuerange of the first extended frame.
 14. The method according to claim 1,further comprising modifying a luminance value of the first extendedframe to obtain a second extended frame when the luminance value of thefirst extended frame is not within a luminance value range of the firstextended frame.
 15. The method according to claim 14, further comprisingskipping modifying the luminance value of the first extended frame toobtain the second extended frame when the luminance value of the firstextended frame is within the luminance value range.
 16. The methodaccording to claim 1, further comprising obtaining a luminance value xof a pixel location of the first extended frame using an inversefunction of the luminance mapping function.
 17. The method according toclaim 16, further comprising mapping the luminance value x to obtain anexpected value fx.
 18. The method according to claim 17, determiningthat a luminance value range of the first extended frame is [fx−ix,fx+ax] according to the luminance value x, the expected value fx, and anexposure relationship between the extended frame and the referenceframe, wherein ix and ax are fixed limit constants.
 19. The methodaccording to claim 17, further comprising modifying the luminance valueof the first extended frame as the expected value fx.
 20. An apparatusfor correcting a multi-exposure motion image, comprising: a memoryconfigured to store an instruction; and a processor configured toexecute the instruction stored in the memory so as to: map a luminanceof an extended frame by using a luminance mapping relationship between areference frame and multiple extended frames to obtain a virtual frame;calculate a global motion vector between the virtual frame and thereference frame; correct a pixel of the extended frame in a pointeroffset manner to obtain a first extended frame after correction when theglobal motion vector comprises a translational motion vector; correctthe pixel of the extended frame in an interpolation manner to obtain thefirst extended frame after correction when the global motion vectorcomprises the translational motion vector and a rotational motionvector; detect a pixel of the first extended frame according to thereference frame to obtain a local error pixel of the first extendedframe; and correct a luminance of the local error pixel of the firstextended frame to obtain a second extended frame after correction.